<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib prefix="tissue" tagdir="/WEB-INF/tags/tissueTags" %>
<%@ taglib prefix="extraction" tagdir="/WEB-INF/tags/tissueExtractionTags" %>
<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Display Tissue</title>

<jsp:include page="includes/header.jsp"></jsp:include>
<script type="text/javascript" src="scripts/gridCommon.js"></script>
<script type="text/javascript" src="scripts/common.js"></script>
<script type="text/javascript" src="scripts/displayTissue.js"></script>

<!--DHTMLXCOMMON-->
<script type="text/javascript" src="scripts/dhtmlxwindows-codebase/dhtmlxcommon.js" ></script>

<!-- DHTMLXWINDOWS -->
<link rel="STYLESHEET" type="text/css" href="scripts/dhtmlxwindows-codebase/dhtmlxwindows.css">
<link rel="STYLESHEET" type="text/css" href="scripts/dhtmlxwindows-codebase/skins/dhtmlxwindows_dhx_skyblue.css">
<script type="text/javascript" src="scripts/dhtmlxwindows-codebase/dhtmlxcontainer.js" ></script>
<script type="text/javascript" src="scripts/dhtmlxwindows-codebase/dhtmlxcommon.js" ></script>
<script type="text/javascript" src="scripts/dhtmlxwindows-codebase/dhtmlxwindows.js" ></script>

<!-- DHTMLXCALENDAR -->
<script type="text/javascript">
window.dhx_globalImgPath = "scripts/dhtmlxcalendar-codebase/imgs/";
</script>
<script type="text/javascript" src="scripts/dhtmlxcalendar-codebase/dhtmlxcalendar.js" ></script>
<link rel="STYLESHEET" type="text/css" href="scripts/dhtmlxcalendar-codebase/dhtmlxcalendar.css">

<!-- DHTMLXFORM -->
<link rel="stylesheet" type="text/css" href="scripts/dhtmlxform-codebase/skins/dhtmlxform_dhx_skyblue.css">
<script type="text/javascript" src="scripts/dhtmlxform-codebase/dhtmlxform.js" ></script>

<script type="text/javascript">
	var form ;
	var receptionDateCal;
	var surgeryDateCal;
	var birthDateCal;
	var lastNewsDateCal;
	var relapseDateCal;
	var deathDateCal;
	
	var currentTissue;
	var displayingUnsetVariables = false;

	var existingTissuesList;
	var existingTissueTypesList;
	
	var changedModalities = new Array();
	var newModalities = new Hash();
	
	var currentTissueUnsetGenericVariables;
	
	var variablesWithCustomInput = new Array();
	
	// ids of the input that contain dhtmlxcalendars
	var calIDs = new Array("receptionDate","surgeryDate","birthDate","lastNewsDate","relapseDate","dateOfDeath");
	

</script>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
</head>
<body onload="doInitWin();initCal();initForm();loadInitialTissue();">

<div id="container">
<div id="top">
<h1>CHC DB Web</h1>
</div>
<div id="leftnav"><jsp:include page="./includes/leftnav.jsp"></jsp:include></div>
<div id="content">
<h2>Display Single Tissue</h2>

<form method="post" action="mainServlet"><input type="hidden" id="appAction" name="appAction"
	value="displayTissue" />
<fieldset><legend>Tissue Selection</legend>
<p>Select the tissue you wish to display :</p>

<label for="chcID">Tissue CHC ID<span class="required">*</span><span style="font-style: italic;font-size: .8em;">(CHC00<span style="color: red;">1</span>T)</span></label>
<input type="text" id="chcID" value="${fn:escapeXml(tissue.chcID)}" name="chcID" size="15" 
	maxlength="15" /> 
<span class="error">${displayTissueForm.messages.chcID}</span> <br />

<label for="tissueTypeID">Tissue Type ID<span class="required">*</span><span style="font-style: italic;font-size: .8em;">(CHC001<span style="color: red;">T</span>)</span> :</label>
<input type="text" id="tissueTypeID" name="tissueTypeID" size="15" maxlength="15"
	value="${fn:escapeXml(tissue.tissueTypeID)}" />
<span class="error">${displayTissueForm.messages.tissueTypeID} </span> <br />

<br/>
<input type="button" value="Display" class="withoutLabel" onClick="displayTissue();"/> 



</fieldset>

<br/>
<fieldset><legend id="tissueInfoTitle">Tissue Info</legend>
<label>CHC ID</label>
<div id="chcIDcurrentTissue"></div>

<label>TissueType</label>
<div id="tissueTypeIDcurrentTissue"></div>
<br/>
<label>Simple Diagnosis</label>
<select id="simpleDiagnosis" onchange="addChangedModality(this.id);">
<option>Benign</option>
<option>Malignant</option>
<option>Cell Line</option>
<option>Non Tumoral</option>
<option selected="selected">-</option>
<option>NA</option>
</select>
<br/>
<label>Sample origin</label>
	<select id="sampleType" onchange="addChangedModality(this.id);">
	<option>Surgery</option>
	<option>Biopsy</option>
	<option>Both</option>
	<option selected="selected">-</option>
	<option>NA</option>
	</select>
<br/>
<label>Tissue Quantity Left</label>
<div id="quantityLeft">${tissue.quantityLeft}</div>
<br />
<label>Associated Tissues</label>
<div id="associatedTissuesDiv"></div>

<br />
<label>Master tissue : </label>
<div id="masterTissueDiv"></div>
<div id="newMasterTissueDiv">
<label> NEW Master tissue CHC ID: </label>
<input type="text" size="15" maxlength="15" id="newMasterTissueCHCID">
<br/>
<label> NEW Master tissue Type ID: </label>
<select id="newMasterTissueTypeID"> </select>
<br/>

<input type="button" value="Associate" onClick="associateNewMaster();" class="withoutLabel">
</div>
<%-- <c:if test="${!empty  tissue.tissueExtractions}"> --%>
<!-- 	<label>Tissue Extractions</label> -->
<!-- 	<div class="largeresult" > -->
<!-- 		<table class="extractiontable" > -->
<!-- 			<thead class="extractiontable"> -->
<!-- 				<tr> -->
<!-- 				<td class="extractiontable">Experimenter</td> -->
<!-- 				<td class="extractiontable">Concentration</td> -->
<!-- 				<td class="extractiontable">Gel quality</td> -->
<!-- 				<td class="extractiontable">Date</td> -->
<!-- 				<td class="extractiontable">Type</td> -->
<!-- 				<td class="extractiontable">Comment</td> -->
<!-- 				</tr> -->
<!-- 			</thead> -->
<%-- 			<c:forEach items="${tissue.tissueExtractions }" var="extraction"> --%>
<%-- 				<extraction:row xtract="${extraction }" /> --%>
<%-- 			</c:forEach> --%>
<!-- 		</table> -->
<!-- 	</div> -->
<%-- </c:if> --%>
</fieldset>
<br/>
<fieldset id="newTissueFieldSet"><legend>New Tissue</legend>
<label>CHC ID</label>
<input type="text" id="chcIDnewTissue"/>
<br/>
<label>TissueType</label>
<select  id="tissueTypeIDnewTissue" ></select>
<br/>
</fieldset>

<br/>
</form>

<div id="tissueData" class="tissueData">
<form id="tissueDataForm">
<fieldset><legend>Clinical Data</legend>
<table>
<tr>
	<td align="right">Clinical center : </td><td>
		<input size="10" onchange="addChangedModality(this.id);" id="clinicalCenter" type="text"></td>
 	<td style="padding-left: 15px" align="right" >Reception Date : </td>
 	<td>
 		<input size="11" onchange="addChangedModality(this.id);" id="receptionDate" readonly="readonly" type="text"></td>
 	<td style="padding-left: 15px" align="right">Anapath ID : </td><td>
 		<input onchange="addChangedModality(this.id);" id="anapathID" type="text"></td>
</tr>
<tr>
	<td align="right">First Name : </td><td>
		<input size="10" onchange="addChangedModality(this.id);" id="firstName" type="text"></td>
	<td style="padding-left: 15px" align="right">Sex : </td><td>
		<select onchange="checkSex();addChangedModality(this.id);" id="sex">
		<option>F</option><option>M</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td align="right">Age : </td><td>
	<input onchange="addChangedModality(this.id);" id="age" type="text" size="5"/></td>
</tr>
<tr>
	<td style="padding-left: 15px" align="right">Date of birth : </td><td>
		<input onchange="addChangedModality(this.id);" type="text" size="11" id="birthDate" readonly="readonly"></td>
	<td style="padding-left: 15px" align="right">Place of birth : </td><td>
		<input size="10" onchange="addChangedModality(this.id);" type="text" id="placeOfBirth"></td>
	<td align="right">Number of Children :</td><td>
		<input size="5" onchange="addChangedModality(this.id);" id="nChildren" type="text"/></td>
</tr>
<tr>
	<td colspan="1" align="right">Age at menopause :</td><td colspan="1">
		<input onchange="addChangedModality(this.id);" size="5" id="ageMenopause" type="text"/></td>
	<td align="right">Profession : </td><td>
		<input size="10" onchange="addChangedModality(this.id);" type="text" id="profession"></td>
	<td style="padding-left: 15px" align="right" colspan="1">Surgery date : </td>
		<td colspan="1">
		<input  size="11"type="text" id="surgeryDate" onchange="addChangedModality(this.id);" readonly="readonly"></td>
</tr>
<tr><td>&nbsp;</td>
</tr>
<tr>
	<td style="padding-left: 15px" align="right" colspan="2">Pre-surgery treatment : 
		<select onchange="checkPreSurgeryTreatment();addChangedModality(this.id);" id="preSurgeryTreatment">
			<option>YES</option>
			<option>NO</option>
			<option selected="selected">-</option>
			<option>NA</option></select></td>
	<td style="padding-left: 15px" align="right" colspan="2">
		<select onchange="checkPreSurgeryTreatmentOther();addChangedModality(this.id);" 
		multiple="multiple" size="6" id="preSurgeryTreatmentDetail">
		<option>Hepatic transplantation</option>
		<option>Hepatectomy</option>
		<option>Chemotherapy</option>
		<option>Chemoembolization</option>
		<option>Other</option>
		<option selected="selected">-</option>
		</select></td>
	<td style="padding-left: 15px" align="right" >Other &nbsp;&nbsp;&nbsp;<br/>pre-surgery treatment : </td><td>
		<textarea id="preSurgeryTreatmentDetailOther" onchange="addChangedModality(this.id);"></textarea></td>
		
</tr>
<!-- <tr> -->
<!-- 	<td align="right">Hepatopathy :</td><td colspan="5"> -->
<!-- 	<textarea id="hepatopathy" cols="100" rows="3"></textarea></td> -->
<!-- </tr> -->


</table>
</fieldset>
<br/>
<fieldset><legend>Biological Data</legend>
<table>
<tr>
	<td align="right">Alpha foeto : </td><td>
		<input size="10" type="text" onchange="addChangedModality(this.id);" id="alphaFoeto"></td>
	<td style="padding-left: 15px" align="right">Billirubin : </td><td>
		<input size="10" type="text" onchange="addChangedModality(this.id);" id="billirubin"></td>
	<td style="padding-left: 15px" align="right">Albumin : </td><td>
		<input size="10" type="text" onchange="addChangedModality(this.id);" id="albumin"></td>
</tr>
<tr>
	<td style="padding-left: 15px" align="right">TP : </td><td>
		<input type="text" size="10" onchange="addChangedModality(this.id);" id="tp"></td>
	<td align="right">Child Pugh : </td><td><select onchange="addChangedModality(this.id);" id="childPugh">
		<option>A</option>
		<option>B</option>
		<option>C</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td align="right">Ascites : </td><td><select onchange="addChangedModality(this.id);" id="ascites">
		<option>YES</option><option>NO</option><option selected="selected">-</option>
		<option>NA</option></select></td>
</tr>
</table>
</fieldset>
<br/>
<fieldset><legend>Non Tumoral Liver Data</legend>
<table>
<tr >
	<td style="padding-left: 15px;" align="right">Histology : </td><td>
		<select  onChange="addChangedModality(this.id);checkCirrhosis();" id="normalLiverHistology">
		<option>Normal Liver</option>
		<option>Cirrhosis</option>
		<option>Portal Fibrosis</option>
		<option>Hepatoportal Sclerosis</option>
		<option>Chronic Active Hepatitis</option>
		<option selected="selected">-</option>
		</select></td>
	<td style="padding-left: 15px;" align="right">Cirrhosis : </td>
		<td><input type="checkbox"  onchange="addChangedModality(this.id);" id="micronodularCirrhosis">micronodular<br/>
			<input type="checkbox" onchange="addChangedModality(this.id);"  id="macronodularCirrhosis">macronodular</td>
</tr>
<tr>
	<td style="padding-left: 15px" align="right">Metavir : </td><td>
		<select  onchange="addChangedModality(this.id);" id="AMetavir"><option>A0</option>
		<option>A1</option><option>A2</option><option>A3</option>
		<option selected="selected">-</option>
		<option >NA</option>
		</select>
		<select  onchange="addChangedModality(this.id);" id="FMetavir">
		<option>F1</option>
		<option>F2</option><option>F3</option>
		<option>F4</option><option selected="selected">-</option>
		<option >NA</option>
		</select></td>
	<td style="padding-left: 15px" align="right">Iron overload (Searle) : </td><td>
		<select  onchange="addChangedModality(this.id);"  id="ironOverloadValue">
		<option>0</option>
		<option>1</option>
		<option>2</option>
		<option>3</option>
		<option>4</option>
		<option selected="selected">-</option>
		<option >NA</option>
		</select></td>
	<td align="right">Steatosis : </td><td>
		<select  onchange="addChangedModality(this.id);" id="ntSteatosis">
		<option>0</option>
		<option>1</option>
		<option>2</option>
		<option>3</option>
		<option>4</option>
		<option selected="selected">-</option>
		<option >NA</option>
		</select>
		</td>
</tr>
<tr>
	<td align="right">Hepatocytic dysplasia : </td><td>
	<select id="hepatocyticDysplasia" onchange="addChangedModality(this.id);">
		<option>Small cells</option>
		<option>Large cells</option>
		<option>Both</option>
		<option>None</option>
		<option selected="selected">-</option>
		<option >NA</option>
		</select></td>
	<td align="right">Associated tumor : </td><td>
	<select id="associatedTumor" onchange="addChangedModality(this.id);">
		<option>Adenoma</option>
		<option>FNH</option>
		<option>Angioma</option>
		<option>HNR</option>
		<option selected="selected">-</option>
		<option >NA</option>
		</select></td>
</tr>
<tr>
	<td align="right">Other lesions : </td><td colspan="1">
		<select  onchange="checkOtherLesions();addChangedModality(this.id);" id="otherLesions" >
		<option>Von Meyenburg complexes</option>
		<option>Glycogenic foci</option>
		<option>Peliosis</option>
		<option>Biliary adenoma</option>
		<option>Other</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select>
		</td>
	<td align="right" colspan="4">
		<textarea  onchange="addChangedModality(this.id);"  id="otherLesionsMisc" rows="3" cols="40"></textarea>
		</td>
</tr>
<tr>
</tr>
 </table>
</fieldset>
<br/>
<fieldset><legend>Risk Factors</legend>
<table >
<tr>
	<td align="right">Hepatitis B :</td><td colspan="3">
		<select  onchange="addChangedModality(this.id);" id="hbv">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td align="right">Hepatitis C :</td><td>
		<select  onchange="addChangedModality(this.id);" id="hcv">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
</tr>
<tr>
	<td align="right">AgHBs : </td><td><select id="agHBs"  onchange="addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td style="padding-left: 15px" align="right">PCR HBX NT Liver : </td><td>
		<select id="pcrHBXNTLiver"  onchange="addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
	<td style="padding-left: 15px" align="right">AcHCV :</td><td>
		<select id="acHCV" onchange="addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
</tr>
<tr>
	<td align="right">AcHBc : </td><td><select id="acHBc" onchange="addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td style="padding-left: 15px" align="right">PCR HBX T Liver : </td><td>
		<select id="pcrHBXTLiver" onchange="addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td style="padding-left: 15px" align="right">PCR HCV NT Liver :</td><td>
		<select id="pcrHCVNTLiver" onchange="addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
</tr>
<tr>
	<td align="right">HBV Viral DNA : </td>
		<td><select id="hbvViralDNA" onchange="addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option><option>NA</option></select></td>
	<td style="padding-left: 15px" align="right">HBV Histochemistry : </td><td>
		<select id="hbvHistoChemistry" onchange="addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td style="padding-left: 15px" align="right">PCR HCV T Liver :</td><td>
		<select id="pcrHCVTLiver" onchange="addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
</tr>
<tr>
</tr>
<tr>
	<td align="right" colspan="1">Other virus :</td><td colspan="1">
		<input onchange="addChangedModality(this.id);" id="otherVirus" type="text" size="20">
		</td>
	<td  align="right">Auto-immune disease :</td><td colspan="2">
		<select  id="autoimmuneDisease" onchange="addChangedModality(this.id);" >
		<option>Auto-immune hepatitis</option>
		<option>Primary biliary cirrhosis</option>
		<option>Primary sclerosing cholangitis</option>
		<option>Unknown / suspected</option>
		<option>NO</option>
		<option selected="selected">-</option><option>NA</option></select></td>
</tr>
<tr ><td >&nbsp;</td>
</tr>
<tr>
	<td align="right" >Alcohol : </td><td colspan="2"><table><tr><td>
		<select  onchange="checkAlcohol();addChangedModality(this.id);" id="alcohol">
		<option>YES</option>
		<option>Occasional</option>
		<option>NO</option>
		<option selected="selected">-</option></select>
		</td></tr><tr>
	<td><select id="alcoholQuantity" onchange="addChangedModality(this.id);">
		<option>&lt;30 g/day (F) or &lt;40 g/day (M) </option>
		<option>30-60 g/day (F) or 40-60 g/day (M) </option>
		<option>60-80 g/day</option>
		<option>&gt;80 g/day</option>
		<option selected="selected">-</option><option>NA</option></select></td></tr></table>
		
	<td align="right" >Tobacco : </td><td colspan="2"><table><tr><td>
		<select  onchange="checkTobacco();addChangedModality(this.id);" id="tobacco">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td></tr><tr>
	<td><input size=5 id="tobaccoQuantity" onchange="addChangedModality(this.id);"/> Packs/year
		</td></tr></table></td>
	
</tr>
<tr><td>&nbsp;</td>
</tr>
<tr>
	<td style="padding-left: 15px" align="right">Hemochromatosis : </td><td>
		<select id="hemochromatosis" onchange="addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
	<td style="padding-left: 15px" align="right">Glycogenosis : </td><td>
		<select id="glycogenosis" onchange="addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option><option>NA</option></select></td>
	<td style="padding-left: 15px" align="right">NASH : </td><td>
		<select id="NASH" onchange="addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option>Suspicion</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td> 
</tr>
<tr>
	<td align="right">Diabetes : </td><td><select id="diabetes" onchange="checkDiabetes();addChangedModality(this.id);" >
		<option>YES</option><option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td align="right">For how many years : </td><td>
		<input size="3" id="diabetesYears" onchange="addChangedModality(this.id);" /></td>
	<td align="right">Diabetes type : </td><td><select  id="diabetesType" onchange="addChangedModality(this.id);" >
		<option>Type 1</option>
		<option>Type 2</option>
		<option>MODY 3</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
		
</tr>

<tr>
	<td align="right">BMI : </td><td><input id="bmi" size="3" onchange="addChangedModality(this.id);" /></td>
	<td align="right">Height (cm) : </td><td><input size="3" id="height" onchange="addChangedModality(this.id);" /></td>
	<td align="right">Weight (kg) : </td><td><input size="3" id="weight" onchange="addChangedModality(this.id);" /></td>
</tr>
<tr>
	<td align="right">Oral Contraception : </td><td>
		<select id="oralContraception" onchange="checkContraception();addChangedModality(this.id);" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td align="right">Age at first use : </td><td>
		<input size="3" id="contraceptionAgeFirstUse" onchange="addChangedModality(this.id);" /></td>
	<td align="right">Number of years used : </td><td>
		<input size="3" id="contraceptionYearsUsed" onchange="addChangedModality(this.id);" /></td>
</tr>
<tr>
	<td align="right" colspan="1">Contraception Type : </td><td colspan="5">
		<textarea cols="80"  id="contraceptionType" onchange="addChangedModality(this.id);" ></textarea></td>
</tr>
<tr><td>&nbsp;</td>
</tr>
<tr>
	<td align="right">On long term drugs : </td><td>
		<select id="longTermDrugs" onchange="checkLongTermDrugs();addChangedModality(this.id);">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td colspan="1" rowspan="2">
		<select multiple="multiple" size="6" id="longTermDrugsTypes" 
			onchange="checkLongTermDrugsOther();addChangedModality(this.id);">
		<option>Barbiturates</option>
		<option>Hormones</option>
		<option>Sexual Hormones</option>
		<option>Steroids</option>
		<option>Other</option>
		<option selected="selected">-</option></select></td>
	<td align="right" rowspan="2">Other drugs :</td><td rowspan="2" colspan="1">
		<textarea id="longTermDrugsMisc"></textarea></td>
</tr>
<tr>
	<td align="right">Years of use : </td><td>
	<input type="text" size="4" id="longTermDrugsYears" onchange="addChangedModality(this.id);"></td>
</tr>
<tr><td>&nbsp;</td>
</tr>

<tr>
	<td align="right">Geographic Origin : </td><td>
		<select id="geographicOrigin" onchange="checkGeographicOrigin();addChangedModality(this.id);">
		<option>France</option>
		<option>Mediterranean Basin</option>
		<option>Africa</option>
		<option>Asia</option>
		<option>Other</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select>
	</td>
	<td align="right" colspan="1">Other geographic origin: </td><td colspan="3">
		<input onchange="addChangedModality(this.id);" id="otherGeographicOrigin" type="text" size="35"/></td>
			
</tr>
<tr>
	<td align="right" colspan="1" rowspan="2">
			<table>
			<tr><td align="center" colspan="2">Stay &gt; 6 months : </td></tr>
			<tr><td align="right">Africa : </td><td>
				<select id="stayInAfrica" onchange="addChangedModality(this.id);">
				<option>YES</option>
				<option>NO</option>
				<option selected="selected">-</option>
				<option>NA</option>
				</select>
			</td></tr>
			<tr><td align="right">Asia : </td><td>
				<select id="stayInAsia" onchange="addChangedModality(this.id);">
				<option>YES</option>
				<option>NO</option>
				<option selected="selected">-</option>
				<option>NA</option>
				</select>
			</td></tr>
			</table></td>
	<td></td><td align="right">Other risk factor : </td><td colspan="4">
		<textarea id="riskFactorsMisc" onchange="addChangedModality(this.id);" cols="30" rows="3"></textarea></td>
</tr>
</table>
</fieldset>
<br/>
<fieldset><legend>Familial Data</legend>
<table>
<tr>
	<td align="right"> Family history of diabetes : </td><td>
		<select id="familyDiabetes" onchange="checkFamilyDiabetes();addChangedModality(this.id);">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td align="right" rowspan="2"> Diabetes type : </td><td rowspan="2">
		<select multiple="multiple" size="4" id="familyDiabetesType" 
			onchange="checkFamilyDiabetesType();addChangedModality(this.id);">
		<option>Type 1</option>
		<option>Type 2</option>
		<option>MODY 3</option>
		<option selected="selected">-</option></select></td> 
	<td align="right" rowspan="2"> Treatment /&nbsp;&nbsp;&nbsp;<br/> regimen for : </td><td rowspan="2">
		<select multiple="multiple" size="5" id="familyTreatmentRegimen" 
			onchange="checkTreatmentRegimen();addChangedModality(this.id);">
		<option>Hypertension</option>
		<option>Hypercholesterolemia</option>
		<option>Hypertriglyceridemia</option>
		<option>Diabetes</option>
		<option selected="selected">-</option></select>
</tr>
<tr>
	<td align="right">Family history of Obesity : </td><td>
	<select id="familyObesity" onchange="addChangedModality(this.id);">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option><option>NA</option></select></td>
</tr>
<tr>
	<td align="right">Familial polyposis coli : </td><td>
		<select id="familyPolyposisColi" onchange="addChangedModality(this.id);">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
	<td align="right" colspan="3">Familial liver&nbsp;&nbsp;&nbsp;<br/>adenomas/adenomatosis/MODY3 :</td><td>
		<select id="familyAdenomasAdenomatosisMODY3" onchange="addChangedModality(this.id);">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
</tr>
<tr>
	<td align="right" >Malignant primary liver tumors :</td><td>
		<select id="familyMalignantPrimaryLiverTumors" 
			onchange="checkFamilyMalignantPrimaryTumors();addChangedModality(this.id);">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
	<td  colspan='3' align="right" >Specify malignant primary liver tumors :</td><td>
		<textarea id="familyMalignantPrimaryLiverTumorsDescription" onchange="addChangedModality(this.id);"></textarea></td>
</tr>
<tr>
	<td align="right" >Family history of malignant tumors :</td><td>
		<select id="familyHistoryMalignantTumors" onchange="checkFamilyHistoryTumors();addChangedModality(this.id);">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
	<td  colspan='3' align="right" >Specify history of malignant tumors :</td><td>
		<textarea id="familyHistoryMalignantTumorsDescription" onchange="addChangedModality(this.id);"></textarea></td>
</tr>

</table>
</fieldset>
<br/>
<table>
<tr><td>
<fieldset><legend>Survival Data</legend>
<table>
<tr>
	<td align="right">Last news date : </td><td>
		<input readonly="readonly" type="text" size="11" id="lastNewsDate" onchange="addChangedModality(this.id);"/></td>
</tr>
<tr>
	<td align="right">Alive <input id="isAlive" onchange="addChangedModality(this.id);" type="checkbox"> : </td><td >
		<select id="aliveWithOrWithoutRelapse" onchange="addChangedModality(this.id);">
			<option >Without relapse</option>
			<option>With relapse</option>
			<option selected="selected">-</option>
			<option>NA</option>
			</select></td>
	<td style="padding-left: 15px" align="right">Relapse date : </td><td>
		<input type="text" size="11" id="relapseDate" onchange="addChangedModality(this.id);" readonly="readonly"/></td>
</tr>
<tr>
	<td align="right">Deceased <input id="isDeceased" onchange="addChangedModality(this.id);" type="checkbox"> :</td><td align="right">
		<select id="deathFromDiseaseOtherEtiology" onchange="addChangedModality(this.id);">
		<option>From disease</option>
		<option>From other etiology</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
	<td style="padding-left: 15px" align="right">Date of death : </td><td>
	<input type="text" size="11" id="dateOfDeath" onchange="addChangedModality(this.id);" readonly="readonly"/></td>
</tr>
<tr>
	<td align="right">Survival wo/ relapse : </td><td>
		<input id="survivalWoRelapse" onchange="addChangedModality(this.id);" type="text" size="5"/></td>
</tr>
<tr>
	<td align="right">Total survival : </td><td>
		<input id="totalSurvival" onchange="addChangedModality(this.id);"type="text" size="5"/></td>
</tr>
</table>
</fieldset>
</td>
<td>
<fieldset ><legend>Relapse Treatment</legend>
<table>
<!-- <tr><td align="right">Hepatic transplantation : </td><td> -->
<!-- 	<select><option>YES</option> -->
<!-- 	<option>NO</option> -->
<!-- 	<option selected="selected">-</option> -->
<!-- 	<option>NA</option></select></td></tr> -->
<!-- <tr><td align="right">Hepatectomy : </td><td> -->
<!-- 	<select><option>YES</option> -->
<!-- 	<option>NO</option> -->
<!-- 	<option selected="selected">-</option> -->
<!-- 	<option>NA</option></select></td></tr> -->
<!-- <tr><td align="right">Chemoembolization : </td><td> -->
<!-- 	<select><option>YES</option> -->
<!-- 	<option>NO</option> -->
<!-- 	<option selected="selected">-</option> -->
<!-- 	<option>NA</option> -->
<!-- 	</select></td></tr> -->
<!-- <tr><td align="right">Alcoholization : </td><td> -->
<!-- 	<select><option>YES</option> -->
<!-- 	<option>NO</option> -->
<!-- 	<option selected="selected">-</option> -->
<!-- 	<option>NA</option></select></td></tr> -->
<!-- <tr><td align="right">Chemotherapy : </td><td> -->
<!-- 	<select><option>YES</option> -->
<!-- 	<option>NO</option> -->
<!-- 	<option selected="selected">-</option> -->
<!-- 	<option>NA</option></select></td></tr> -->
<!-- <tr><td align="center" colspan="2"><select></select></td></tr> -->
<tr><td rowspan="2" align="center">
	<select id="relapseTreatment" onchange="checkRelapseTreatment();addChangedModality(this.id);" multiple="multiple" size="7">
			<option>Hepatic transplatation</option>
			<option>Hepatectomy</option>
			<option>Chemoembolization</option>
			<option>Alcoholization</option>
			<option>Chemotherapy</option>
			<option>Other</option>
			<option selected="selected">-</option>
</select>
</td>
<td align="center">Other treatment : </td>
</tr>
<tr><td align="right"><textarea id="relapseTreatmentMisc" rows="7" onchange="addChangedModality(this.id);"></textarea></td></tr>
</table>
</fieldset>
</td></tr>
</table>
<fieldset > <legend>Pathology</legend>
<table>
<tr>
	<td align="right">Number of distal&nbsp;&nbsp;&nbsp;<br/> nodules (&gt; 1cm) : </td><td>
		<input onchange="addChangedModality(this.id);" id="nbDistalNodules" type="text" size="5"></td>
	<td align="right">Distal satellites &nbsp;&nbsp;&nbsp;<br/>nodules (&lt; 1cm) : </td><td>
		<select onchange="addChangedModality(this.id);"  id="distalSatelliteNodules">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option>
	</select></td>
</tr>

<tr>
	<td align="right">Vascular invasion : </td><td>
		<select onchange="addChangedModality(this.id);"  id="vascularInvasion">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td align="right">Portal invasion : </td><td>
		<select onchange="addChangedModality(this.id);"  id="portalInvasion">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
</tr>
<tr>
	<td align="right">Macroscopic portal invasion : </td><td>
		<select  onchange="addChangedModality(this.id);" id="macroscopicPortalInvasion">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td align="right">Microscopic portal invasion :</td><td>
		<select  onchange="addChangedModality(this.id);" id="microscopicPortalInvasion">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
</tr>
<tr>
	<td align="right">Nodule Size &nbsp;&nbsp;&nbsp;<br/>(largest axis, im mm) : </td><td>
		<input  size="5" onchange="addChangedModality(this.id);" id="noduleSizeLargestAxis" type="text" >
		</td>
	<td align="right">Surgical Margin (mm) : </td><td>
		<input onchange="addChangedModality(this.id);"  id="surgicalMargin" type="text" >
		</td>
</tr>
<tr>
	<td align="right">Edmonson grade : </td><td>
		<select  onchange="addChangedModality(this.id);" id="edmonsonGrade">
		<option>I</option>
		<option>II</option>
		<option>III</option>
		<option>IV</option>
		<option selected="selected">-</option
		><option>NA</option></select></td>
	<td align="right">Differentiation (WHO) : </td><td>
		<select  onchange="addChangedModality(this.id);" id="differenciationWHO" >
		<option>Good</option>
		<option>Medium</option>
		<option>Weak</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
</tr>
<tr>

	<td align="right">Histological Pattern : </td><td>
		<select size="7" multiple="multiple"  
			onchange="checkHistologicalPattern();addChangedModality(this.id);" id="histologicalPattern">
		<option>Microtrabecular</option>
		<option>Macrotrabecular</option>
		<option>Pseudoglandular</option>
		<option>Compact</option>
		<option>Diffused</option>
		<option>Scirrhous</option>
		<option selected="selected">-</option></select></td>
</tr>
<tr>
	<td align="right">Degree of nuclear atypia :</td><td>
		<select  onchange="addChangedModality(this.id);" id="nuclearAtypiaDegree">
		<option>0</option>
		<option>1</option>
		<option>2</option>
		<option>3</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td align="right">Intranuclear inclusion :</td><td>
		<select  onchange="addChangedModality(this.id);" id="intranuclearInclusion">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
</tr>
<tr>
	<td align="right">Clear cells :</td><td><select  onchange="addChangedModality(this.id);" id="clearCells">
		<option>YES</option>
		<option>YES (sparse)</option>
		<option>YES (very sparse)</option>
		<option>NO</option>
		<option selected="selected">-</option><option>NA</option></select></td>
	<td align="right">Eosinophilic inclusions :</td><td>
		<select  onchange="addChangedModality(this.id);" id="eosinophilicInclusions">
		<option>YES</option>
		<option>YES (sparse)</option>
		<option>YES (very sparse)</option>
		<option>YES (Mallory body)</option>
		<option>YES (sparse / Mallory body)</option>
		<option>NO</option>
		<option selected="selected">-</option>
		</select></td>
</tr>
<tr>
	<td align="right">Sarcomatoid appearance :</td><td>
		<select  onchange="addChangedModality(this.id);" id="sarcomatoidAppearance">
		<option>YES</option><option>NO</option><option selected="selected">-</option><option>NA</option></select></td>
	<td align="right">Osteoclast-like cells :</td><td>
		<select  onchange="addChangedModality(this.id);" id="osteoclastLikeCells">
		<option>YES</option><option>NO</option><option selected="selected">-</option><option>NA</option></select></td>
</tr>
<tr>
	<td align="right">Oncocytic cells :</td><td><select  onchange="addChangedModality(this.id);" id="oncocyticCells">
		<option>YES</option><option>NO</option><option selected="selected">-</option><option>NA</option></select></td>
	<td align="right">Tumoral cholestasis :</td><td><select  onchange="addChangedModality(this.id);" id="tumoralCholestasis">
		<option>YES</option><option>NO</option><option selected="selected">-</option><option>NA</option></select></td>
</tr>
<tr>
	<td align="right">Fibrotic Stroma :</td><td><select  onchange="addChangedModality(this.id);" id="fibroticStroma">
		<option>YES</option>
		<option>YES (minimal)</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
	<td align="right">Inflammation :</td><td>
		<select  onchange="checkInflammation();addChangedModality(this.id);" id="inflammation" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select>
		<select  onchange="addChangedModality(this.id);" id="inflammationType">
			<option>Lymphocytic</option><option>Neutrophils</option><option>Mixed</option>
			<option selected="selected">-</option>
			<option>NA</option></select>
	</td>
</tr>
<tr>
	<td align="right">Peliosis / Hemorrhage :</td>
		<td><select  onchange="addChangedModality(this.id);" id="peliosisHemorrhage">
		<option>YES</option>
		<option>YES (minimal)</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
	<td align="right">Perineural invasion :</td><td><select  onchange="addChangedModality(this.id);" id="perineuralInvasion">
		<option>YES</option><option>NO</option><option selected="selected">-</option><option>NA</option></select></td>
</tr>
<tr>
	<td align="right">Biliary invasion :</td><td>
	<select  onchange="addChangedModality(this.id);" id="biliaryInvasion">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td align="right" >Tumoral capsule : </td><td>
		<select onchange="addChangedModality(this.id);" id="tumoralCapsule">
		<option>Absent</option>
		<option>Intact</option>
		<option>Invaded</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
</tr>
<tr>
	<td align="right">Glisson capsule invasion :</td><td>
	<select  onchange="addChangedModality(this.id);" id="glissonCapsuleInvasion">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td align="right" valign="middle">Extra-hepatic &nbsp;&nbsp;&nbsp;<br/>tissue invasion :</td>
	<td valign="middle"><table><tr><td>
	<select  onchange="checkExtraHepaticInvasion();addChangedModality(this.id);" id="extraHepaticInvasion" >
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td><td>
	<select  onchange="addChangedModality(this.id);" id="extraHepaticInvasionTissue"  multiple="multiple" size="7">
		<option>Abdominal cavity</option>
		<option>Adipose tissue</option>
		<option>Adrenal gland</option>
		<option>GallBlader</option>
		<option>GallBlader adventitia</option>
		<option>Peritoneum</option>
		<option selected="selected" >-</option>
		</select></td></tr></table></td>
</tr>
<tr>
	<td align="right">Necrosis : </td><td>
		<input type="text" id="necrosis" onchange="addChangedModality(this.id);"></td>
	<td align="right">Tumoral steatosis : </td><td>
		<select id="tumoralSteatosis" onchange="addChangedModality(this.id);">
		<option>0</option>
		<option>1</option>
		<option>1</option>
		<option>3</option>
		<option>4</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
</tr>
<tr>
	<td align="right">Hepatic vein invasion : </td><td>
		<select id="hepaticVeinInvasion" onChange="addChangedModality(this.id)">
		<option>YES</option>
		<option>NO</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
</tr>
<tr>

	<td align="right">Miscellaneous :</td><td colspan="3">
		<textarea   onchange="addChangedModality(this.id);" id="miscellaneousPathologicalData" cols="70" rows="3">
		</textarea></td>
	
</tr>

</table>
</fieldset>
<br/>

<fieldset><legend>Immuno-Histo Chemistry</legend>
<table>
<tr>
	<td align="right">&beta;Cat (membrane) :</td><td>
		<select onchange="addChangedModality(this.id);" id="ihcBCATmembrane">
		<option>0</option>
		<option>1</option>
		<option>2</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
	<td align="right">&beta;Cat (cytoplasm) :</td><td>
		<select id="ihcBCATcytoplasm" onchange="addChangedModality(this.id);">
		<option>0</option>
		<option>1</option>
		<option>2</option>
		<option selected="selected">-</option>
		<option>NA</option>
		</select></td>
	<td align="right">&nbsp;&beta;Cat (nucleus) : </td><td>
		<select id="ihcBCATnucleus" onchange="addChangedModality(this.id);">
		<option>0</option>
		<option>1</option><option>2</option>
		<option selected="selected">-</option><option>NA</option></select></td>
</tr>
<tr>
	<!-- &#37; = % (percent) symbol	-->
	<td align="right">CK19 Tumor:</td><td>
		<select id="ihcCK19Tumor"  onchange="addChangedModality(this.id);">
		<option>0-1 (&lt;10&#37;)</option>
		<option>2 (&gt; 10&#37; - &lt;50&#37;)</option>
		<option>3 (&gt;50&#37;)</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
</tr>

<tr>
	<td align="right">EPCAM Tumor:</td><td>
		<select id="ihcEPCAMTumor" onchange="addChangedModality(this.id);">
		<option>0-1 (&lt;10&#37;)</option>
		<option>2 (&gt; 10&#37; - &lt;50&#37;)</option>
		<option>3 (&gt;50&#37;)</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
	<td align="right">GS :</td><td colspan="3">
		<select id="ihcGSlocalization" onchange="addChangedModality(this.id);">
		<option>Negative</option><option>Focal</option>
		<option>Diffused</option>
		<option selected="selected">-</option>
		<option>NA</option></select>
		<select id="ihcGSintensity" onchange="addChangedModality(this.id);">
		<option>Strong</option>
		<option>Heterogeneous</option>
		<option selected="selected">-</option>
		<option>NA</option></select></td>
</tr>
<tr>
	<td align="right">Adrenomedulin Tumor</td><td>
		<select id="ihcAdrenomedulinTumor" onchange="addChangedModality(this.id);">
		<option>0</option>
		<option>1</option>
		<option>2</option>
		<option>3</option>
		<option>4</option>
		<option selected="selected">-</option>
		<option>NA</option></select>
	<td align="right">Adrenomedulin NT Liver</td><td>
		<select id="ihcAdrenomedulinNTLiver"  onchange="addChangedModality(this.id);">
		<option>0</option>
		<option>1</option>
		<option>2</option>
		<option>3</option>
		<option>4</option>
		<option selected="selected">-</option>
		<option>NA</option></select>
</tr>
<tr>
	<td align="right">RAMP3 Tumor</td><td>
		<select id="ihcRAMP3Tumor" onchange="addChangedModality(this.id);">
		<option>0</option>
		<option>1</option>
		<option>2</option>
		<option>3</option>
		<option>4</option>
		<option selected="selected">-</option>
		<option>NA</option></select>
	<td align="right">RAMP3 NT Liver</td><td>
		<select id="ihcRAMP3NTLiver" onchange="addChangedModality(this.id);">
		<option>0</option>
		<option>1</option>
		<option>2</option>
		<option>3</option>
		<option>4</option>
		<option selected="selected">-</option>
		<option>NA</option></select>
</tr>
</table>
</fieldset>
<br/>
<br/>
<br/>

<fieldset><legend>Generic Variables</legend>
<input type="button" id="addModalityButton" 
	onClick="toggleDisplayingUnsetVariables();" value="display/hide variables with no modalities">
<table id="genericVariablesContainer">
</table>
<input type="button" id="addModalityButtonBottom" 
	onClick="toggleDisplayingUnsetVariables();" value="display/hide variables with no modalities">
</fieldset>
</form>
</div>
<br/>
<input type="button" value="Save Modifications" onclick="saveTissue();" />
</div>
<div id="footer"><jsp:include page="./includes/footer.jsp"></jsp:include></div>
</div>

</body>
</html>